if __name__ == '__main__':
    def demo2():
        try:
            a = int(input("请输入利润："))
            b = 0
            if 0 < a <= 10:
                b += a * 0.1
            elif 10 < a <= 20:
                b += 10 * 0.1
                b += (a-10) * 0.075
            elif 20 < a <= 40:
                b += 10 * 0.1
                b += 10 * 0.075
                b += (a-20) * 0.05
            elif 40 < a <= 60:
                b += 10 * 0.1
                b += 10 * 0.075
                b += 20 * 0.05
                b += (a-20) * 0.03
            elif 60 < a <= 100:
                b += 10 * 0.1
                b += 10 * 0.075
                b += 20 * 0.05
                b += 20 * 0.03
                b += (a-40) * 0.015
            elif a > 100:
                b += 10 * 0.1
                b += 10 * 0.075
                b += 20 * 0.05
                b += 20 * 0.03
                b += 40 * 0.015
                b += (a - 100) * 0.01
            else:
                return "None"
            return b
        except:
            print("请输入正确的参数，请重新运行")
    print(demo2())
